package cn.lm.activiti.spring;

import org.springframework.context.ApplicationContext;
import org.springframework.context.ApplicationContextAware;
import org.springframework.context.support.ClassPathXmlApplicationContext;

/**
 * @author lm_jcf
 * @date 2019/4/5 19:04
 */
public class TestMain {

    public static void main(String[] args) {
        // 1 常见Spring 的IOC容器对象
        ApplicationContext context = new ClassPathXmlApplicationContext("applicationContext.xml");

        // 2 从IOC容器中获取Bean实例
        HelloWorld helloWorld = (HelloWorld) context.getBean("helloWorld");
        helloWorld.hello();
    }
}
